import request from '@/utils/request'

export function tree() {
    return request({
        url: '/sys/dept/tree',
        method: 'get',
    })
}
export function authTopTree() {
    return request({
        url: '/sys/dept/auth-top-tree',
        method: 'get',
    })
}
export function pageTree() {
    return request({
        url: '/sys/dept/page-tree',
        method: 'get',
    })
}
export function authTree() {
    return request({
        url: '/sys/dept/auth-tree',
        method: 'get',
    })
}
export function add(data) {
    return request({
        url: '/sys/dept/add',
        method: 'post',
        data
    })
}
export function edit(data) {
    return request({
        url: '/sys/dept/edit',
        method: 'post',
        data
    })
}
export function del(id) {
    return request({
        url: '/sys/dept/delete/' + id,
        method: 'post',
    })
}
export function move(data) {
    return request({
        url: '/sys/dept/move',
        method: 'post',
        data
    })
}
export function sync() {
    return request({
        url: '/sys/dept/sync',
        method: 'post',
    })
}
